:root{
    --left-bg-color:rgba(87,84,236,.3);
    --right-bg-color:rgba(43,43,43,.8);
    --left-btn-hover-color:rgba(87,84,236,1);
    --right-btn-hover-color:rgba(28,122,28,1);
    --hover-width:75%;
    --other-width:25%;
    --speed:1000ms;

}
*{
    box-sizing: border-box;
}
body{
    height: 100vh;
    overflow: hidden;
    margin: 0;

}
.container{
    position: relative;
    width: 100%;
    height: 100%;
    background-color: #333;
}
.split{
    position: absolute;
    width: 50%;
    height: 100%;

}
h1{
    /* 可以自适应 -- 随着页面字体大小变化 */
    font-size: 4rem;
    color: white;
    position: absolute;
    left: 50%;
    top: 20%;
    transform: translateX(-50%);
    white-space: nowrap;
}
.btn{
    position: absolute;
    display: flex;
    justify-content: center;
    align-items: center;
    left: 50%;
    top: 40%;
    transform: translateX(-50%);
    text-transform:uppercase;
    color: white;
    text-decoration: none;
    border: white solid 0.2rem;
    font-size: 1rem;
    font-weight: bold;
    widows: 15rem;
    padding: 1.5rem;
}
.split.left .btn:hover{
     background-color: var(--left-btn-hover-color);
     border-color: var(--left-btn-hover-color);
}
.split.right .btn:hover{
    background-color: var(--right-btn-hover-color);
    border-color: var(--right-btn-hover-color);
}
.split.left{
    left: 0;
    background-image: url('https://50projects50days.com/projects/split-landing-page/ps.jpg');
    background-repeat: no-repeat;
    background-size: cover;
}
.split.left::before{
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background-color: var(--left-bg-color);
}
.split.right{
    right: 0;
    background-image: url('https://50projects50days.com/projects/split-landing-page/xbox.jpg');
    background-repeat: no-repeat;
    background-size: cover;
}
.split.right::before{
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background-color: var(--right-bg-color);
}
.split.left,
.split.right,
.split.left::before,
.split.right::before{
    transition: all var(--speed) ease-in-out;
}
.hover-left .left{
    width: var(--hover-width);
}
.hover-left .right{
    width: var(--other-width);
}
.hover-right .left{
    width: var(--other-width);
}
.hover-right .right{
    width: var(--hover-width);
}
@media (max-width:800px) {
    h1{
        font-size: 2rem;
        top: 30%;
    }
    .btn{
        padding: 1.2rem;
        width: 12rem;
    }
}